<?php
use yii\helpers\Html;
use yii\helpers\ArrayHelper;
?>


<div class="modal-dialog ">
	<div class="modal-content">
		<div class="modal-header">
			<button aria-hidden="true" data-dismiss="modal" class="close" type="button">×</button>
			<h4 class="modal-title">管理员详细信息</h4>
		</div>
		<div class="modal-body">
			<table class="table table-striped table-condenseda table-bordered">
				<tbody>
					<tr>
						<th width="25%">用户名</th>
						<td width="75%"><?= Html::encode($admin['username']) ?></td>
					</tr>
					<tr>
						<th>当前角色</th>
						<td>
							<?php foreach($role as $key => $val){?>
								<?php if($val['is_checked'] == 1){?>
									<li style="display:block;float:left;width:100px;height:25px;"><?= Html::encode($val['role_remark']) ?></li>
								<?php } ?>
							<?php }?>
						</td>
					</tr>

					<tr>
						<th>Email</th>
						<td><?= Html::encode($admin['email']) ?></td>
					</tr>
					<tr>
					
					<tr>
						<th>注册时间</th>
						<td>
							<?= date("Y-m-d H:i:s",Html::encode($admin['created_at'])) ?>
						</td>
					</tr>

					<tr>
						<th>最近登录时间/IP</th>
						<td> 
							<?php echo date("Y-m-d H:i:s",Html::encode($admin['login_time'])); ?>/
							<?= Html::encode($admin['login_ip']) ?>
						</td>
					</tr> 

					<tr>
						<th>修改时间</th>
						<td>
							<?php echo date("Y-m-d H:i:s",Html::encode($admin['updated_at'])); ?>
						</td>
					</tr>
				</tbody>
			</table>
		</div>
		<div class="modal-footer">  <button data-dismiss="modal" class="btn btn-primary" type="button">关闭</button>
		</div>
	</div>
</div>